<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="author" content="Laurence-042">
    
    
    
    
    
    
    <title>JavaGUI_Swing学习笔记 | Laurence</title>
    <link href=”https://laurence-042.github.io“ rel=”prefetch” />

    <link rel="stylesheet" href="/css/bootstrap.min.css">
<link rel="stylesheet" href="/css/aos.css">
<link rel="stylesheet" href="/css/style.css">
    <script src="/js/jquery.min.js"></script>
    <script src="/js/bootstrap.min.js"></script>
    <script src="/js/aos.js"></script>
    <script src="/js/highslide/highslide-full.min.js"></script>
    <link rel="stylesheet" href="/js/highslide/highslide.css">
    <style type="text/css">
        @media (max-width: 768px) {
            body {
                background-color: #f0f0f0;
                background: url('/imgs/xsbg.jpg');
                background-attachment: fixed;
            }
        }
    </style>
    
    <!--<script type="text/javascript">
      if (document.images) {
        var avatar = new Image();
        avatar.src = '/imgs/dr.png'
        var previews = 'http://bing.ioliu.cn/v1/rand'.split(',')
        var previewsPreLoad = []
        for(var i = 0; i < length; i++) {
          previewsPreLoad.push(new Image())
          previewsPreLoad[previewsPreLoad.length - 1].src = '/imgs/preview' + previews[i]
        }
      }
    </script>-->

    <!--highlight.js-->
    <link rel="stylesheet" href="//cdn.bootcss.com/highlight.js/9.2.0/styles/github.min.css">
    <script src="//cdn.bootcss.com/highlight.js/9.2.0/highlight.min.js"></script>
</head>
<body>
    <!-- 背景轮播图功能 -->
    <section class="hidden-xs">
    <ul class="cb-slideshow">
        <li><span>天若</span></li>
        <li><span>有情</span></li>
        <li><span>天亦老</span></li>
        <li><span>我为</span></li>
        <li><span>长者</span></li>
        <li><span>续一秒</span></li>
    </ul>
</section>
    <!-- 欧尼酱功能, 谁用谁知道 -->
    
    <header class="navbar navbar-inverse" id="gal-header">
    <div class="container">
        <div class="navbar-header">
            <button type="button" class="navbar-toggle collapsed"
                    data-toggle="collapse" data-target=".bs-navbar-collapse"
                    aria-expanded="false">
                <span class="fa fa-lg fa-reorder"></span>
            </button>
            <a href="https://laurence-042.github.io">
                
                <style>
                    #gal-header .navbar-brand {
                        height: 54px;
                        line-height: 24px;
                        font-size: 28px;
                        opacity: 1;
                        background-color: rgba(0,0,0,0);
                        text-shadow: 0 0 5px #fff,0 0 10px #fff,0 0 15px #fff,0 0 20px #228DFF,0 0 35px #228DFF,0 0 40px #228DFF,0 0 50px #228DFF,0 0 75px #228DFF;
                    }
                </style>
                <!-- 这里使用文字(navbar_text or config.title) -->
                <div class="navbar-brand">Laurence</div>
                
            </a>
        </div>
        <div class="collapse navbar-collapse bs-navbar-collapse">
            <ul class="nav navbar-nav" id="menu-gal">
                
                
                <li class="">
                    <a href="/">
                        <i class="fa fa-home"></i>首页
                    </a>
                </li>
                
                
                
                <li class="">
                    <a href="/archives">
                        <i class="fa fa-archive"></i>归档
                    </a>
                </li>
                
                
                
                
                <li class="">
                    <a href="/categories">
                        <i class="fa fa-list"></i>分类
                    </a>
                </li>
                
                
                
                
                
                <li class="dropdown">
                    <!-- TODO 添加hover dropdown效果 -->
                    <a href="#" class="dropdown-toggle" data-toggle="dropdown"
                       aria-haspopup="true" aria-expanded="false" data-hover="dropdown">
                        <i class="fa fa-tags"></i>标签
                    </a>
                    <ul class="dropdown-menu">
                        
                        
                        <li>
                            <a href="/tags/Java/">Java</a>
                        </li>
                        
                        <li>
                            <a href="/tags/笔记/">笔记</a>
                        </li>
                        
                        <li>
                            <a href="/tags/日常/">日常</a>
                        </li>
                        
                        <li>
                            <a href="/tags/纯记忆的学习笔记/">纯记忆的学习笔记</a>
                        </li>
                        
                        <li>
                            <a href="/tags/Python/">Python</a>
                        </li>
                        
                        <li>
                            <a href="/tags/不定期更新/">不定期更新</a>
                        </li>
                        
                        
                        <li>
                            <a href="/tags">...</a>
                        </li>
                        
                        
                    </ul>
                </li>
                
                
                
                
                <li class="">
                    <a href="/about">
                        <i class="fa fa-user"></i>关于我
                    </a>
                </li>
                
                
            </ul>
        </div>
    </div>
</header>
    <div id="gal-body">
        <div class="container">
            <div class="row">
                <div class="col-md-8 gal-right" id="mainstay">
                    
<article class="article well article-body" id="article">
    <div class="breadcrumb">
        <i class="fa fa-home"></i>
        <a href="https://laurence-042.github.io">Laurence</a>
        >
        <span>JavaGUI_Swing学习笔记</span>
    </div>
    <!-- 大型设备详细文章 -->
    <div class="hidden-xs">
        <div class="title-article">
            <h1>
                <a href="/2018/07/18/JavaGUI-Swing学习笔记/">JavaGUI_Swing学习笔记</a>
            </h1>
        </div>
        <div class="tag-article">
            
            <span class="label label-gal">
                <i class="fa fa-tags"></i>
                
                <a href="/tags/Java/">Java</a>, 
                
                <a href="/tags/笔记/">笔记</a>
                
            </span>
            
            <span class="label label-gal">
                <i class="fa fa-calendar"></i> 2018-07-18
            </span>
            
        </div>
    </div>
    <!-- 小型设备详细文章 -->
    <div class="visible-xs">
        <center>
            <div class="title-article">
                <h4>
                    <a href="/2018/07/18/JavaGUI-Swing学习笔记/">JavaGUI_Swing学习笔记</a>
                </h4>
            </div>
            <p>
                <i class="fa fa-calendar"></i> 2018-07-18
            </p>
            <p>
                
                <i class="fa fa-tags"></i>
                
                <a href="/tags/Java/">Java</a>, 
                
                <a href="/tags/笔记/">笔记</a>
                
                
                
            </p>
        </center>
    </div>
    <div class="content-article">
        <a id="more"></a>
<h2 id="JButton点击事件"><a href="#JButton点击事件" class="headerlink" title="JButton点击事件"></a>JButton点击事件</h2><pre><code class="Java">//为变量名为btn的按钮添加点击事件
btn.addActionListener(new ActionListener(){
    @Override
    public void actionPerformed(ActionEvent arg0) {
        System.out.print(&quot;Button Clicked&quot;);
    }           
});//没错，这么5大行玩意是一条语句，是个匿名内部类，并重写了addActionListener的actionPerformed方法
</code></pre>
<p><a href="https://www.cnblogs.com/shocker/archive/2012/07/19/2598653.html" target="_blank" rel="noopener">此段代码为转载，并为了突出重点做了一些修改，可点击此处查看来源</a></p>
<h2 id="JTable表格的数据来源"><a href="#JTable表格的数据来源" class="headerlink" title="JTable表格的数据来源"></a>JTable表格的数据来源</h2><p>不太推荐用这个，还是用JTextArea配合JScrollPane灵活性更高一些也更方便（还没有坑爹的上限200条的限制）</p>
<pre><code class="Java">JTable table = new JTable(obj, columnNames);
/*
obj为二维数组，表示表格的数据来源
比如
Object[][] obj = new Object[2][6];
用此处的obj作数据源的表格将是一个2行6列的表格

columnNames为一维数组，表示第一行的对数据含义的解释（比如“姓名”，“年龄”等等）
当然，columnName的元素数应和obj的列数相同
*/
</code></pre>
<p><a href="https://blog.csdn.net/caihanyuan/article/details/7320434" target="_blank" rel="noopener">此段代码为转载，并为了突出重点做了一些修改，可点击此处查看来源</a></p>
<h2 id="JTextArea配合JScrollPane展示数据"><a href="#JTextArea配合JScrollPane展示数据" class="headerlink" title="JTextArea配合JScrollPane展示数据"></a>JTextArea配合JScrollPane展示数据</h2><pre><code class="Java">JScrollPane scrollPane = new JScrollPane();
scrollPane.setBounds(0, 0, 326, 209);
mainPanel.add(scrollPane);
// 主界面的数据展示区
JTextArea mainTextArea = new JTextArea();
scrollPane.setViewportView(mainTextArea);
</code></pre>
<p>可以使用以下代码进行数据填充,Student可以为任意数据存储单元</p>
<pre><code class="Java">StringBuffer sb = new StringBuffer();
for (Student st : students) {
    sb.append(st.toString()).append(&quot;\n&quot;);
}
ta.setText(sb.toString());
ta.setEditable(false);
</code></pre>
<p><a href="http://localhost:4000/" target="_blank" rel="noopener">此段代码主要为老师给的，自己在上面根据需要改了改，没有链接</a></p>
<h2 id="JOptionPane的几种样式"><a href="#JOptionPane的几种样式" class="headerlink" title="JOptionPane的几种样式"></a>JOptionPane的几种样式</h2><pre><code class="Java">JOptionPane.showMessageDialog(null, &quot;我是普通提示框！╮(╯▽╰)╭&quot;);  

JOptionPane.showMessageDialog(null, &quot;我是警告提示框！╮(╯▽╰)╭&quot;, &quot;标题&quot;,JOptionPane.WARNING_MESSAGE);  

JOptionPane.showMessageDialog(null, &quot;我是错误提示框！╮(╯▽╰)╭&quot;, &quot;标题&quot;,JOptionPane.ERROR_MESSAGE); 

JOptionPane.showMessageDialog(null, &quot;我是最基本提示框！╮(╯▽╰)╭&quot;, &quot;标题&quot;,JOptionPane.PLAIN_MESSAGE);

int n = JOptionPane.showConfirmDialog(null, &quot;你会了吗?&quot;, &quot;标题&quot;,JOptionPane.YES_NO_OPTION); //返回值为0或1

Object[] options ={ &quot;必须是&quot;, &quot;当然是&quot; };  //自定义按钮上的文字
int m = JOptionPane.showOptionDialog(null, &quot;钓鱼岛是中国的吗？&quot;, &quot;标题&quot;,JOptionPane.YES_NO_OPTION, JOptionPane.QUESTION_MESSAGE, null, options, options[0]);  

Object[] obj2 ={ &quot;路人甲&quot;, &quot;路人乙&quot;, &quot;路人丙&quot; };  
String s = (String) JOptionPane.showInputDialog(null,&quot;请选择你的身份:\n&quot;, &quot;身份&quot;, JOptionPane.PLAIN_MESSAGE, new ImageIcon(&quot;icon.png&quot;), obj2, &quot;足球&quot;);

JOptionPane.showInputDialog(null,&quot;请输入：\n&quot;,&quot;title&quot;,JOptionPane.PLAIN_MESSAGE); 
</code></pre>
<p><a href="https://blog.csdn.net/c1481118216/article/details/51921521" target="_blank" rel="noopener">此段代码为转载，并为了突出重点做了一些修改，可点击此处查看来源</a></p>
<h2 id="JFreeChart与JPanel结合"><a href="#JFreeChart与JPanel结合" class="headerlink" title="JFreeChart与JPanel结合"></a>JFreeChart与JPanel结合</h2><p>下面的类的作用是创建一个容纳图像的panel</p>
<pre><code class="Java">class ImagePanel extends JPanel {

    /**
     * 用于展示统计数据时使用的JFreeChart生成的图片 图片大小和这个panel的大小一致
     */
    private static final long serialVersionUID = 1L;

    private BufferedImage image;

    public ImagePanel() {
        super();
    }

    public void setImage(BufferedImage image) {
        this.image = image;
    }

    protected void paintComponent(Graphics g) {
        super.paintComponent(g);
        g.setColor(Color.white);

        if (null != image) {
            this.setSize(image.getWidth(this), image.getHeight(this));
            g.fill3DRect(0, 0, image.getWidth(this), image.getHeight(this), true);
            g.drawImage(image, 0, 0, null, this);
            setPreferredSize(new Dimension(image.getWidth(this), image.getHeight(this)));
        }
    }
}
</code></pre>
<p>为了生成这个图片，我们需要一个dataset来存储图表所用的信息，以生成十个柱的统计学生BMI值分布的柱状图的方法为例</p>
<pre><code class="Java">public static IntervalXYDataset createDataset(ArrayList&lt;Student&gt; students) {
    // 创建用于展示柱状图的Dataset
    XYSeriesCollection seriesCollection = new XYSeriesCollection();
    XYSeries series1 = new XYSeries(&quot;BMI Statistics&quot;);

    // 获取最大最小值以及它们的差，用于生成十个数据区间
    float max = getMaxBmi(students);
    float min = getMinBmi(students);
    float size = (max - min) / 10;
    float nowLower = min;
    int nowPos = 0;// 代表当前在bmi数组的位置

    // 创建一个排好序的储存全部学生bmi的数组，以免影响到学生对象原本的排序
    float[] bmi = new float[students.size()];
    for (int i = 0; i &lt; bmi.length; i++) {
        bmi[i] = students.get(i).getBmi();
    }
    Arrays.sort(bmi);

    // 分成十个区间，每个区间的最小值当作代表值
    for (int i = 0; i &lt; 10; i++) {
        int num = 0;

        if (i == 9) {// 若无此判断，在最后一次循环里会因算法问题无法获取正确的人数
            num = bmi.length - nowPos;
            series1.add(nowLower, num);
        } else {
            for (int j = nowPos; j &lt; bmi.length; j++) {
                if (bmi[j] &gt; nowLower + size) {
                    num = j - nowPos;
                    nowPos = j;
                    break;
                }
            }
            series1.add(nowLower, num);
            nowLower = nowLower + size;
        }

    }
    seriesCollection.addSeries(series1);
    return new XYBarDataset(seriesCollection, 0.9);
}
</code></pre>
<p>为了方便随时更新这个图表的图片，我们还需要一个用于更新的方法<br>这个方法里的<em>data</em>，<em>chart</em>，“image”是我那个主类里存储相应数据的成员变量，分别存储dataset，生成图表所用的chart和这个chart转化的图像<br>而statisticsImagePanel则是我实例化的一个ImagePanel对象，就是上面说的那个可以挂在Jpanel下面的，用来展示图表的panel</p>
<pre><code class="Java">public void flushChartImage() {
    // 刷新统计的图片
    data = createDataset(students);
    chart = ChartFactory.createXYBarChart(&quot;BMI Statistics&quot;, &quot;Intervals&quot;, false, &quot;Number of Students&quot;, data,
            PlotOrientation.VERTICAL, true, false, false);
    image = chart.createBufferedImage(statisticsImagePanel.getBounds().width,
            statisticsImagePanel.getBounds().height, BufferedImage.TYPE_INT_RGB, null);

    statisticsImagePanel.setImage(image);
}
</code></pre>
<p>现在只要把下面一段代码加到你想生成这个统计图表的位置就行了，显然我准备把这个图表挂在statisticsPanel这个panel下面，你需要根据自己的需要选择生成的位置</p>
<pre><code class="Java">ImagePanel statisticsImagePanel = new ImagePanel();
statisticsImagePanel.setBounds(10, 34, 409, 188);
statisticsPanel.add(statisticsImagePanel);
</code></pre>
<p>其实想起来也不算很难，说白了关键其实就是“chart图表-&gt;图片构造器-&gt;图片-&gt;容纳图片的panel”这么个转化途径，自己写一遍你就会发现······<br>这玩意真™麻烦，而且也不算很常用，用的时候再看一下再Ctrl+C一下再Ctrl+V一下就好了嘛（笑）   </p>
<p><a href="http://localhost:4000/" target="_blank" rel="noopener">此段代码主要为老师给的，自己在上面根据需要改了改，没有链接</a></p>
<h2 id="JMenu的使用"><a href="#JMenu的使用" class="headerlink" title="JMenu的使用"></a>JMenu的使用</h2><pre><code class="Java">JMenuBar jMenuBar = new JMenuBar();
JMenu jMenu = new JMenu(&quot;菜单&quot;);
JMenuItem item1 = new JMenuItem(&quot;主界面&quot;);
item1.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent arg0) {
        switchPanel(mainPanel);
    }
});
JMenuItem item2 = new JMenuItem(&quot;输入&quot;);
item2.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent arg0) {
        switchPanel(inputPanel);
    }
});
JMenuItem item3 = new JMenuItem(&quot;维护&quot;);
item3.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent arg0) {
        switchPanel(maintainPanel);
    }
});
JMenuItem item4 = new JMenuItem(&quot;统计&quot;);
item4.addActionListener(new ActionListener() {
    public void actionPerformed(ActionEvent arg0) {
        switchPanel(statisticsPanel);
    }
});
jMenu.add(item1);
jMenu.add(item2);
jMenu.add(item3);
jMenu.add(item4);
jMenuBar.add(jMenu);
// 这里是添加标题栏
frame.setJMenuBar(jMenuBar);
</code></pre>
<p>其中，<code>switchPanel()</code>是一个自己写的函数，用于在同一窗口切换Panel，很简单就能实现（但用百度有点难查到）</p>
<pre><code class="Java">private void switchPanel(JPanel panel) {
    frame.getContentPane().removeAll();
    frame.getContentPane().add(panel);
    frame.getContentPane().revalidate();
    frame.getContentPane().repaint();
}
</code></pre>
<!--more-->

    </div>
</article>


<div id="comments-template"></div>
<link rel="stylesheet" href="https://imsun.github.io/gitment/style/default.css">
<script>
	if(!window.commentConfig) {
      window.commentConfig = {}
      window.commentConfig.title = 'JavaGUI_Swing学习笔记'
    }
</script>

                </div>
                <aside class="col-md-4 gal-left" id="sidebar">
    <!-- 此为sidebar的搜索框, 非搜索结果页面 -->
<aside id="sidebar-search">
    <div class="search hidden-xs" data-aos="fade-up" data-aos-duration="2000">
        <form class="form-inline clearfix" id="search-form" method="get"
              action="/search/index.html">
            <input type="text" name="s" class="form-control" id="searchInput" placeholder="搜索文章~">
            <button class="btn btn-danger btn-gal" type="submit">
                <i class="fa fa-search"></i>
            </button>
        </form>
    </div>
</aside>
    <aside id="sidebar-author">
    <div class="panel panel-gal" data-aos="flip-right" data-aos-duration="3000">
        <div class="panel-heading" style="text-align: center">
            <i class="fa fa-quote-left"></i>
            Laurence-042
            <i class="fa fa-quote-right"></i>
        </div>
        <div class="author-panel text-center">
            <img src="/imgs/dr.png" width="140" height="140"
                 alt="个人头像" class="author-image">
            <p class="author-description"></p>
        </div>
    </div>
</aside>
    
    <aside id="sidebar-recent_comments">
    <div class="panel panel-gal recent hidden-xs" data-aos="fade-up" data-aos-duration="2000">
        <div class="panel-heading">
            <i class="fa fa-comments"></i>
            最新评论
            <i class="fa fa-times-circle panel-remove"></i>
            <i class="fa fa-chevron-circle-up panel-toggle"></i>
        </div>
        <ul class="list-group list-group-flush"></ul>
    </div>
</aside>
    
    <!-- 要配置好leancloud才能开启此小工具 -->
    
    
    <aside id="sidebar-recent_posts">
    <div class="panel panel-gal recent hidden-xs" data-aos="fade-up" data-aos-duration="2000">
        <div class="panel-heading">
            <i class="fa fa-refresh"></i>
            近期文章
            <i class="fa fa-times-circle panel-remove"></i>
            <i class="fa fa-chevron-circle-up panel-toggle"></i>
        </div>
        <ul class="list-group list-group-flush">
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/10/08/一个鶸的自我修养/">一个鶸的自我修养</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/10/08/hello-world/">Hello World</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/08/08/给真·小白的关于初用远程Linux系统的简单入门/">给真·小白的关于初用远程Linux系统的简单入门</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/08/02/令新人各种懵逼的各种概念/">令新人各种懵逼的各种概念</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/31/Python-MySQL数据查询/">Python-MySQL数据查询</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/28/Python笔记-这个鶸仍未搞明白的东西/">Python笔记-这个鶸仍未搞明白的东西</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/26/Python笔记-特殊变量/">Python笔记-特殊变量</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/25/Fullmetal Alchemist!!!/">Fullmetal Alchemist!!!</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/23/Python笔记-陌生的lambda/">Python笔记-陌生的lambda</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/22/DFS-BFS学习笔记/">DFS,BFS学习笔记</a>
                </span>
            </li>
            
        </ul>
    </div>
</aside>
    
    
    <aside id="sidebar-rand_posts">
    <div class="panel panel-gal recent hidden-xs" data-aos="fade-up" data-aos-duration="2000">
        <div class="panel-heading">
            <i class="fa fa-refresh"></i>
            随机文章
            <i class="fa fa-times-circle panel-remove"></i>
            <i class="fa fa-chevron-circle-up panel-toggle"></i>
        </div>
        <ul class="list-group list-group-flush">
            
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/22/DFS-BFS学习笔记/">DFS,BFS学习笔记</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/31/Python-MySQL数据查询/">Python-MySQL数据查询</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/26/Python笔记-特殊变量/">Python笔记-特殊变量</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/23/Python笔记-陌生的lambda/">Python笔记-陌生的lambda</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/10/08/hello-world/">Hello World</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/09/关于Java实现的某些算法的记录/">关于Java实现的某些算法的记录</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/19/关于在Vultr上折腾MySQL的那些事/">关于在Vultr上折腾MySQL的那些事</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/06/30/各种杂项（不定期更新）/">各种杂项（不定期更新）</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/07/09/用bat文件简化hexo操作/">用bat文件简化hexo操作</a>
                </span>
            </li>
            
            <li class="list-group-item">
                <span class="post-title">
                    <a href="/2018/08/08/给真·小白的关于初用远程Linux系统的简单入门/">给真·小白的关于初用远程Linux系统的简单入门</a>
                </span>
            </li>
            
        </ul>
    </div>
</aside>
    
    
    <aside id="gal-sets">
        <div class="panel panel-gal hidden-xs" data-aos="fade-up" data-aos-duration="2000">
            <ul class="nav nav-pills pills-gal">
                <li class="">
                    <a href="/2018/07/18/JavaGUI-Swing学习笔记/index.html#sidebar-tags" data-toggle="tab" id="tags-tab">热门标签</a>
                </li>
                <li class="">
                    <a href="/2018/07/18/JavaGUI-Swing学习笔记/index.html#sidebar-friend-links" data-toggle="tab" id="friend-links-tab">友情链接</a>
                </li>
                <li class="">
                    <a href="/2018/07/18/JavaGUI-Swing学习笔记/index.html#sidebar-links" data-toggle="tab" id="links-tab">个人链接</a>
                </li>
            </ul>
            <div class="tab-content">
                <div class="cloud-tags tab-pane nav bs-sidenav fade" id="sidebar-tags">
    
    <a href="/tags/Java/" style="font-size: 16.410162423667636px;" class="tag-cloud-link">Java</a>
    
    <a href="/tags/笔记/" style="font-size: 10.32340435211876px;" class="tag-cloud-link">笔记</a>
    
    <a href="/tags/日常/" style="font-size: 12.129926570000546px;" class="tag-cloud-link">日常</a>
    
    <a href="/tags/纯记忆的学习笔记/" style="font-size: 13.54876045240612px;" class="tag-cloud-link">纯记忆的学习笔记</a>
    
    <a href="/tags/Python/" style="font-size: 18.355274065656044px;" class="tag-cloud-link">Python</a>
    
    <a href="/tags/不定期更新/" style="font-size: 8.290873920780157px;" class="tag-cloud-link">不定期更新</a>
    
    <a href="/tags/hey/" style="font-size: 8.140635155741352px;" class="tag-cloud-link">hey!</a>
    
    <a href="/tags/报错解决方案/" style="font-size: 14.278807415063149px;" class="tag-cloud-link">报错解决方案</a>
    
    <a href="/tags/MySQL/" style="font-size: 18.38928802871251px;" class="tag-cloud-link">MySQL</a>
    
    <a href="/tags/服务器/" style="font-size: 19.875963801628206px;" class="tag-cloud-link">服务器</a>
    
    <a href="/tags/工具/" style="font-size: 12.12700300367458px;" class="tag-cloud-link">工具</a>
    
    <a href="/tags/hexo/" style="font-size: 13.499637246138066px;" class="tag-cloud-link">hexo</a>
    
    <a href="/tags/bat/" style="font-size: 10.3770366991204px;" class="tag-cloud-link">bat</a>
    
    <a href="/tags/偷懒/" style="font-size: 12.761415446494489px;" class="tag-cloud-link">偷懒</a>
    
    <a href="/tags/真·小白/" style="font-size: 19.339913700836824px;" class="tag-cloud-link">真·小白</a>
    
    <a href="/tags/Linux/" style="font-size: 19.45296179694121px;" class="tag-cloud-link">Linux</a>
    
</div>
                <div class="friend-links tab-pane nav bs-sidenav fade" id="sidebar-friend-links">
    
    <li>
        <a href="http://kdays.net/days/" target="_blank">KDays Forum</a>
    </li>
    
    <li>
        <a href="http://www.gal123.com/" target="_blank">绅士导航♂</a>
    </li>
    
    <li>
        <a href="http://www.moe123.com/" target="_blank">萌导航</a>
    </li>
    
    <li>
        <a href="https://google.jiongjun.cc/" target="_blank">Google镜像站</a>
    </li>
    
</div>
                <div class="links tab-pane nav bs-sidenav fade" id="sidebar-links">
    
    <li>
        <a href="https://github.com/Laurence-042" target="_blank">Github</a>
    </li>
    
    <li>
        <a href="http://localhost:4000/" target="_blank">null,没有更多的了</a>
    </li>
    
</div>
            </div>
        </div>
    </aside>
    
</aside>
            </div>
        </div>
    </div>
    <footer id="gal-footer">
    <div class="container">
        Copyright © 2018 Laurence-042 Powered by <a href="https://hexo.io/" target="_blank">Hexo</a>.&nbsp;Theme by <a href="https://github.com/ZEROKISEKI" target="_blank">AONOSORA</a>
    </div>
</footer>

<!-- 回到顶端 -->
<div id="gal-gotop">
    <i class="fa fa-angle-up"></i>
</div>
</body>
<script src="/js/activate-power-mode.js"></script>
<script>

    // 配置highslide
	hs.graphicsDir = '/js/highslide/graphics/'
    hs.outlineType = "rounded-white";
    hs.dimmingOpacity = 0.8;
    hs.outlineWhileAnimating = true;
    hs.showCredits = false;
    hs.captionEval = "this.thumb.alt";
    hs.numberPosition = "caption";
    hs.align = "center";
    hs.transitions = ["expand", "crossfade"];
    hs.lang.number = '共%2张图, 当前是第%1张';
    hs.addSlideshow({
      interval: 5000,
      repeat: true,
      useControls: true,
      fixedControls: "fit",
      overlayOptions: {
        opacity: 0.75,
        position: "bottom center",
        hideOnMouseOut: true
      }
    })

    // 初始化aos
    AOS.init({
      duration: 1000,
      delay: 0,
      easing: 'ease-out-back'
    });

</script>
<script>
	POWERMODE.colorful = 'true';    // make power mode colorful
	POWERMODE.shake = 'true';       // turn off shake
	// TODO 这里根据具体情况修改
	document.body.addEventListener('input', POWERMODE);
</script>
<script>
    window.slideConfig = {
      prefix: '/imgs/slide/background',
      ext: 'jpg',
      maxCount: '6'
    }
</script>
<script src="/js/hs.js"></script>
<script src="/js/blog.js"></script>



<script src="https://imsun.github.io/gitment/dist/gitment.browser.js"></script>
<script>
    if(window.commentConfig) {
      window.commentConfig.id = 'Wed Jul 18 2018 19:45:02 GMT+0000'
      window.commentConfig.owner = 'Laurence-042'
      window.commentConfig.repo = 'blog-comment'
      window.commentConfig.client_id = '41ecdf7be074fb66a1a2'
      window.commentConfig.client_secret = '2382f17284dc9ba9754020431735338ce8d80ec0'
      window.commentConfig.redirect_uri = ''
    } else {
      window.commentConfig = {
      	id: 'Wed Jul 18 2018 19:45:02 GMT+0000',
        owner: 'Laurence-042',
        repo: 'blog-comment',
        client_id: '41ecdf7be074fb66a1a2',
        client_secret: '2382f17284dc9ba9754020431735338ce8d80ec0',
        redirect_uri: ''
      }
    }
</script>

<!--highlight.js-->
<script>
    hljs.initHighlightingOnLoad();
</script>
<script src="/js/comment/gitment.js"></script>

</html>